﻿@{
    ViewBag.Title = "checkresetpassword";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
@section head{
    <link rel="stylesheet" href="/content/css/pages/page_reg.css" />
}
<div class="breadcrumbs margin-bottom-40">
    <div class="container">
        <h3 class="pull-left blue">
            重设密码</h3>
    </div>
</div>
<div class="container">
    <div class="row-fluid">
        <div class="span6 offset3">
            <div class="tab-v1">
                <div class="tab-content" style="padding-top: 0;">
                    @{
                        RooHui.Infrastructure.Entities.Entity.Member member = ViewBag.User;
                    }
                    <div class="reg-page" style="padding: 5px 10px;" id="mobiletype">
                        <div class="alert alert-success">
                        请输入您的新密码
                        </div>
                        <form id="form" action="/account/setnewpassword" method="post">
                        <input type="hidden" name="u" value="@RooHui.Tool.EncodeByBase64.Encode(member.UserName)" />
                        <div class="row-fluid">
                            <div class="control-group">
                                <label class="control-label">
                                    用户名 ：</label>
                                <div class="controls">
                                    <input class="span12" id="txtusername" value="@member.UserName" disabled="disabled" name="username" type="text" />
                                </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">
                                    重置密码 <span class="color-red">*</span>：</label>
                                <div class="controls">
                                    <input class="span12 {required:true,minlength:6,maxlength:18}" id="txtPassword" name="Password" type="password" />
                                </div>
                            </div>
                            <div class="control-group">
                                <label class="control-label">
                                    确认密码 <span class="color-red">*</span>：</label>
                                <div class="controls">
                                    <input class="span12 {required:true,equalTo:'#txtPassword'}" id="txtconfirm" name="confirm" type="password" />
                                </div>
                            </div>
                            <hr />
                            <button type="submit" class="btn btn-primary span12" style="margin-left: 0">
                                确认</button>
                        </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
@section scripts{
    <script type="text/javascript" src="/content/plugins/jquery-validate/jquery.validate.js"></script>
    <script type="text/javascript" src="/content/plugins/jquery-validate/jquery.metadata.js"></script>
    <script type="text/javascript">
        $(function () {
            $('#form').validate({
                errorClass: "help-inline",
                errorElement: "span",
                highlight: function (element, errorClass, validClass) {
                    $(element).parents('.control-group').addClass('error');
                },
                unhighlight: function (element, errorClass, validClass) {
                    $(element).parents('.control-group').removeClass('error');
                }
            });
        });
    </script>
}
